/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package edu.gmu.javalution.crowd;

/**
 *
 * @author jason.handuber
 */
public class DoubleArrayIndexComparator implements IIndexComparator<double[]>
{
    private int index = -1;

    public void setIndex(int index)
    {
        this.index = index;
    }

    public int compare(double[] o1, double[] o2)
    {
        return Double.compare(o1[index], o2[index]);
    }

}
